<?php
/*  
  Copyright (c) 2010-02 SongCMS 
  SongCMS All Rights Reserved. 
  Support:www.SongCMS.com
  QQ:544255858   19951025
  Author:Song  Version:3.17
  Date:2010-08-12 09:28:32
*/
if(!defined('SONGCMSROOT')) define('SONGCMSROOT','./');
include_once(SONGCMSROOT . 'global.php');
$SC = new SC();
$SC -> caching = $WebStaticCache == "1" ? true : false;
$SC -> force_compile = $WebForceCompil == "1" ? true : false;
$SC -> cache_lifetime = $WebCacheLifetime;
$SC -> debugging = false;
$SC -> template_dir = SONGCMSROOT . $TemDir;
$SC -> compile_dir = SONGCMSROOT . 'tmp/translation';
$SC -> cache_dir  = SONGCMSROOT . 'tmp/cache';
$SC -> left_delimiter = $Delimiter[0];
$SC -> right_delimiter = $Delimiter[1];
function smarty_block_dynamic($param,$content,&$SC){
	return $content;
}
$SC -> register -> block('dynamic','smarty_block_dynamic',false);
$Sys = array(
	'CMSVersion' => $CMSVersion,
	'CMSUpDate' => $CMSUpDate,
	'Charset' => $Charset,
	'isTraditional' => $isTraditional,
	'Lang' => $Lang,
	'Cookies' => $_COOKIE,
	'WebLangKind' => $WebLangKind,
	'TemDir' => './'.$TemDir,
	'WebHost' => $WebHost,
	'isLogin' => @$_COOKIE['isLogin'],
	'sGET' => $sGET,
	'WebStaticHTML' => $WebStaticHTML,
	'URL' => URL(), 
	'mtRand' => mt_rand(), 
	'CodeFile' => basename($File), 
);
include_once(SONGCMSROOT . 'config/slideshow.php');
$plugins = array( 
	'slide' => $slide[$Lang] 
);
$SC -> register -> templateFunction("URL","IDURL"); 
$TemDir = SONGCMSROOT.$TemDir;
@$jcn = mysql_connect($dbhost,$dbuser,$dbpass) or die($Warning[6]);
@mysql_select_db($dbname,$jcn) or die($Warning[6]);
$sdb = new sdb();
$WebConfig = $sdb -> WebConfig($Lang);
extract($WebConfig);
$SC -> assign('Sys',$Sys);
$SC -> assign('Cfg',$SYSTEMCONFIG); 
$SC -> assign('plugins',$plugins);
$SC -> assign('Web',$WebConfig);
$SC -> assign('Html',$Html);
include_once($File);
?>